﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using System.Windows.Media.Animation;

namespace iControl.Controls
{
    /// <summary>
    /// Interaction logic for Marquee.xaml
    /// </summary>
    public partial class Marquee : UserControl
    {
        #region Variable Declaration
        Storyboard _RotateStoryboard;
        #endregion

        #region Constructor
        public Marquee()
        {
            InitializeComponent();

            _RotateStoryboard = this.FindResource("RotateStoryboard") as System.Windows.Media.Animation.Storyboard;
        }
        #endregion

        #region Methods
        public void Animate()
        {
            _RotateStoryboard.Begin(this);
        }
        public void StopAnimation()
        {
            _RotateStoryboard.Stop(this);
        }
        #endregion
    }
}
